class CreateFourOhFours < ActiveRecord::Migration
  def self.up
    create_table :four_oh_fours do |t|
      t.column "host", :string
      t.column "path", :string
      t.column "referer", :string
      t.column "count", :integer, :default => 0
      t.timestamps
    end
    add_index :four_oh_fours, [:host, :path, :referer], :unique => true
    add_index :four_oh_fours, [:path]
  end

  def self.down
    drop_table :four_oh_fours
  end
end
